#include <iostream>
int main()
{
    int sum = 0,val = 1;
    //小于等于10则循环
    while(val<=10){
      sum +=val;
      ++val;
    }
    std::cout <<"从1加到10的累加和为"<< sum << std::endl;
    return 0;
}
